package com.cz.run.beans.mysql;

import com.baomidou.mybatisplus.enums.IdType;
import java.util.Date;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableName;
import java.io.Serializable;

/**
 * <p>
 * 用户推广表
 * </p>
 *
 * @author CAIYJ
 * @since 2018-05-23
 */
@TableName("user_referral")
public class UserReferral extends Model<UserReferral> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    @TableField("user_id")
    private Integer userId;
    /**
     * 推广代码
     */
    private String code;
    /**
     * 完成条件 
     */
    @TableField("condition_value")
    private String conditionValue;
    /**
     * 完成条件说明 
     */
    @TableField("condition_desc")
    private String conditionDesc;
    /**
     * 访问量
     */
    @TableField("visit_count")
    private Integer visitCount;
    /**
     * 注册量
     */
    @TableField("regist_count")
    private Integer registCount;
    /**
     * 0:未开始；1：进行中；-1：已放弃；2：成功
     */
    private Integer status;
    /**
     * 创建时间
     */
    @TableField("create_time")
    private Date createTime;


    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getConditionValue() {
        return conditionValue;
    }

    public void setConditionValue(String conditionValue) {
        this.conditionValue = conditionValue;
    }

    public String getConditionDesc() {
        return conditionDesc;
    }

    public void setConditionDesc(String conditionDesc) {
        this.conditionDesc = conditionDesc;
    }

    public Integer getVisitCount() {
        return visitCount;
    }

    public void setVisitCount(Integer visitCount) {
        this.visitCount = visitCount;
    }

    public Integer getRegistCount() {
        return registCount;
    }

    public void setRegistCount(Integer registCount) {
        this.registCount = registCount;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    @Override
    public String toString() {
        return "UserReferral{" +
        ", id=" + id +
        ", userId=" + userId +
        ", code=" + code +
        ", conditionValue=" + conditionValue +
        ", conditionDesc=" + conditionDesc +
        ", visitCount=" + visitCount +
        ", registCount=" + registCount +
        ", status=" + status +
        ", createTime=" + createTime +
        "}";
    }
}
